import React, { Component } from 'react';
import RouterView from '../../router/router-views';
import {RouteItem} from '../../router/router.d';
import {NavLink} from 'react-router-dom';
import './index.css';
 
interface Iprop{
    routes:RouteItem[]
}

class Main extends Component<Iprop>{
    render() {
        return (
            <div className="wrapper">
                <div className="con">
                    <RouterView routes={this.props.routes}></RouterView>
                </div>
                <footer>
                    <NavLink to="/main/home">首页</NavLink>
                    <NavLink to="/main/my">我的</NavLink>
                </footer>
            </div>
        );
    }
}

export default Main;